package com.jjyu.dao;

import com.jjyu.entity.Promotion;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface PromotionMapper {

    @Select("SELECT * FROM promotion WHERE min_amount <= #{totalAmount}")
    List<Promotion> getApplicablePromotions(double totalAmount);
}